//
//  FindModel.m
//  0000327App
//
//  Created by user on 16/3/29.
//  Copyright © 2016年 MoreMoney. All rights reserved.
//
#import "FindModel.h"

@implementation FindModel
//- (instancetype)initWithTitle:(NSString *)title time:(NSString *)time imageURL:(NSURL *)url detailTitle:(NSString *)detailTitle
//{
//    if (self = [super init]) {
//        
//        self.title = title;
//        self.time = time;
//        self.imageURL = url;
//        self.detailTitle = detailTitle;
//    }
//    return self;
//}

+ (NSArray *)models
{
    NSMutableArray *marr = [NSMutableArray array];
    
    NSArray *array = [NSArray arrayWithContentsOfFile:[[NSBundle mainBundle] pathForResource:@"FindModelPlist.plist" ofType:nil]];
    
    for (NSDictionary *dict in array) {
        
        FindModel *model = [FindModel initWithDict:dict];
        [marr addObject:model];
    }
    
    NSArray *result = marr;
    return result;
}
+ (instancetype) initWithDict:(NSDictionary *)dict
{
    id obj = [[self alloc] init];
    [obj setValuesForKeysWithDictionary:dict];
    return obj;
}
@end
